#include <cstdio>
#include <iostream>
#include <string>
using namespace std;

int main()
{
    string s = "123 456";
    unsigned int u, v;  
    int n = std::sscanf(s.c_str(), "%u%u", &u, &v);
    cout << "n = " << n << endl;
    cout << "u = " << u << endl;
    cout << "v = " << v << endl;
    return 0;
}